home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
MacHack 2000
/
MacHack 2000.toast
/
pc
/
The Hacks
/
Softshoe
/
Lisa's Mac Parts
/
Views
/
Tiled Views
/
RuledPaneRowOfWidth.h
< prev
next >
Wrap
Text File
|
2000-06-23
|
868b
|
42 lines
// RuledPaneRowOfWidth.h
#ifndef RuledPaneRowOfWidth_h
#define RuledPaneRowOfWidth_h
#ifndef PaneRowOfWidth_h
#include "PaneRowOfWidth.h"
#endif
#ifndef ViewCell_h
#include "ViewCell.h"
#endif
#ifndef VerticalBar_h
#include "VerticalBar.h"
#endif
template <uint32 nonRulePanes>
class RuledPaneRowOfWidth: public PaneRowOfWidth< 2 * nonRulePanes - 1 >
{
public:
RuledPaneRowOfWidth()
{
static const VerticalBar<1> verticalLine;
for ( uint32 i = 1; i < 2 * nonRulePanes - 1; i+=2 )
{
PaneRowOfWidth::operator[](i).SetContent( ViewCell::Black() );
PaneRowOfWidth::operator[](i).SetSizer( verticalLine );
}
}
RectangularPane& operator[]( uint32 i )
{
return PaneRowOfWidth::operator[]( 2*i );
}
RectangularPane& operator[]( uint32 i ) const
{
return PaneRowOfWidth::operator[]( 2*i );
}
};
#endif